Tim Berners–Lee invented the World Wide Web. He didn't invent the Internet.
The Internet is the global system of interconnected networks that link computers worldwide, using the Internet protocol suite (the Transmission Control Protocol and the Internet Protocol, or TCP/IP). The World Wide Web is an application that allows documents and other resources to be accessed via the Internet. When you type a URL into your computer, it's the World Wide Web – not the Internet – that finds what you're looking for, using hyper–text transfer protocol (HTTP) and unique resource locators (URLs).
The Internet has been around since the 1960s; it dates back to research commissioned by the United States federal government to build robust, fault–tolerant computer networks. It was in 1989, while working at CERN, that Tim Berners–Lee implemented the first successful communication between an HTTP client and server via the Internet. In order to do this he had to build the first web browser.
If asking what it was that Tim Berners–Lee invented, in a pub quiz, you either need to find some way of steering contestants away from the Internet, or allow "the Internet" as an answer. Not everyone is a computer expert, and the difference is a little arcane to say the least.
© Haydn Thompson 2017